package com.jy.rhin.config.ws;

import com.jy.rhin.support.interceptor.AuditInfoEventSender;
import org.apache.cxf.ext.logging.LoggingInInterceptor;
import org.apache.cxf.ext.logging.LoggingOutInterceptor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @Description:
 * @Author: lww
 * @Date: 2022/5/18
 */
@Configuration
public class InterceptorConfig {

    @Bean
    public LoggingInInterceptor getLoggingInInterceptor(AuditInfoEventSender sender){
        return new LoggingInInterceptor(sender);
    }

    @Bean
    public LoggingOutInterceptor getLoggingOutInterceptor(AuditInfoEventSender sender){
        return new LoggingOutInterceptor(sender);
    }

}
